<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
		<style>
			*{
				margin: 0;
				padding: 0;
			}
			.wp{
				width: 500px;
				height: 400px;
				border: 1px solid red;
				margin: 50px auto 0;
			}
			.wp1{
				position:relative;
			}
			.div1{
				width: 200px;
				height: 200px;
				background-color:green;
				position:absolute;
				left:50%;
				top:50%;
				margin-left:-100px;
				margin-top:-100px;
			}
			
			.wp2{
				display: table;
			}
			.div2{
				display: table-cell;
				vertical-align: middle;
			}
			.div2 p{
				background-color: green;
			}
			
			
			.helper{
				height: 50%;
				margin-bottom: -100px;
				float: left;
			}
			.div3{
				width: 200px;
				height: 200px;
				background-color:green;
				clear: both;
			}
			
			
			.wp4{
				position: relative;
			}
			.div4{
				width: 200px;
				height: 200px;
				background-color:green;
				
				position: absolute;
				top: 0;
				left: 0;
				right: 0;
				bottom: 0;
				margin: auto;
			}
			
			
			.wp5{
				line-height: 400px;
			}
		</style>
	</head>
	<body>
		
		<div class="wp wp1">
			<div class="div1"></div>
		</div>
		
		<div class="wp wp2">
			<div class="div2">
				<p>151654654</p>
			</div>
		</div>
		
		<div class="wp">
			<p class="helper"></p>
			<div class="div3"></div>
		</div>
		
		<div class="wp wp4">
			<div class="div4"></div>
		</div>
		
		<div class="wp wp5">
			<span>我是单行文本</span>
		</div>
	</body>
</html>
